package com.htgd.gardenexpo.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import java.time.LocalDateTime;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * <p>
 * 组织机构表
 * </p>
 *
 * @author author
 * @since 2024-03-01
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("ge_base_depart")
@ApiModel(value="GeBaseDepart对象", description="部门表")
public class GeBaseDepart implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "ID")
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    private String id;

    @ApiModelProperty(value = "父部门ID")
    private String parentId;

    @ApiModelProperty(value = "部门名称")
    private String departName;

    @ApiModelProperty(value = "排序")
    private Integer departOrder;

    @ApiModelProperty(value = "部门类型 1一级部门 2子部门")
    private String orgType;

    @ApiModelProperty(value = "部门编码")
    private String orgCode = "a1";

    @ApiModelProperty(value = "状态（1启用，0不启用）")
    private String status;

    @ApiModelProperty(value = "删除状态（0，正常，1已删除）")
    private String delFlag;

    @ApiModelProperty(value = "创建人")
    private String createBy;
    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @ApiModelProperty(value = "创建日期")

    private LocalDateTime createTime;
    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @ApiModelProperty(value = "更新日期")
    private LocalDateTime updateTime;

    @ApiModelProperty(value = "是否有叶子节点: 1是0否")
    private Boolean izLeaf;

    @ApiModelProperty(value = "负责人姓名")
    private String fzr;

    @ApiModelProperty(value = "负责人ID")
    private Integer fzrId;

    @TableField(exist = false)
    private List<GeBaseDepart> children;

    @TableField(exist = false)
    private String key;

    @TableField(exist = false)
    private String title;

    @TableField(exist = false)
    private String value;


}
